/**
 * Created by lixiaodi on 2019/04/15 0027.
 */
mini.parse();
var formListId;
var processId;
//进入子页面
function SetData(data){
	formListId = data.formListId;
	processId = data.processId;
}
//未结束流程确定
function onNotFinished(){
	$.ajax({
		//url: ajaxUrl + "/activitiFormController/deploy.do",
		url: '',
	    type:"post",
	    data: {
	    	formId: formListId,
	    	modelId: processId
	    },
	    success: function (data) {
	    	console.log(data);
	    },
	    error: function () {
	        mini.alert("失败");
	    }
	})
}
//历史流程不变确定
function historyActivi(){
	$.ajax({
		//url: ajaxUrl + "/activitiFormController/deploy.do",
		url: '',
	    type:"post",
	    data: {
	    	formId: formListId,
	    	modelId: processId
	    },
	    success: function (data) {
	    	console.log(data);
	    },
	    error: function () {
	        mini.alert("失败");
	    }
	})
}
//关闭子页面
function CloseWindow(action) {
    if (action == "close" && form.isChanged()) {
        if (confirm("数据被修改了，是否先保存？")) {
            return false;
        }
    }
    if (window.CloseOwnerWindow) return window.CloseOwnerWindow(action);
    else window.close();
}
function onOk(e) {
    SaveData();
}
function onCancel(e) {
    CloseWindow("cancel");
}